3.15 \(\int x^3 (a+b \tanh ^{-1}(c x))^2 \, dx\)

Optimal. Leaf size=113 \[ \frac{a b x}{2 c^3}-\frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{4 c^4}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2+\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}+\frac{b^2 x^2}{12 c^2}+\frac{b^2 \log \left (1-c^2 x^2\right )}{3 c^4}+\frac{b^2 x \tanh ^{-1}(c x)}{2 c^3} \]

[Out]

(a*b*x)/(2*c^3) + (b^2*x^2)/(12*c^2) + (b^2*x*ArcTanh[c*x])/(2*c^3) + (b*x^3*(a + b*ArcTanh[c*x]))/(6*c) - (a
+ b*ArcTanh[c*x])^2/(4*c^4) + (x^4*(a + b*ArcTanh[c*x])^2)/4 + (b^2*Log[1 - c^2*x^2])/(3*c^4)

________________________________________________________________________________________

Rubi [A]  time = 0.222507, antiderivative size = 113, normalized size of antiderivative = 1., number of steps used = 11, number of rules used = 7, integrand size = 14, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.5, Rules used = {5916, 5980, 266, 43, 5910, 260, 5948} \[ \frac{a b x}{2 c^3}-\frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{4 c^4}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2+\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}+\frac{b^2 x^2}{12 c^2}+\frac{b^2 \log \left (1-c^2 x^2\right )}{3 c^4}+\frac{b^2 x \tanh ^{-1}(c x)}{2 c^3} \]

Antiderivative was successfully verified.

[In]

Int[x^3*(a + b*ArcTanh[c*x])^2,x]

[Out]

(a*b*x)/(2*c^3) + (b^2*x^2)/(12*c^2) + (b^2*x*ArcTanh[c*x])/(2*c^3) + (b*x^3*(a + b*ArcTanh[c*x]))/(6*c) - (a
+ b*ArcTanh[c*x])^2/(4*c^4) + (x^4*(a + b*ArcTanh[c*x])^2)/4 + (b^2*Log[1 - c^2*x^2])/(3*c^4)

Rule 5916

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)*((d_.)*(x_))^(m_.), x_Symbol] :> Simp[((d*x)^(m + 1)*(a + b*ArcT
anh[c*x])^p)/(d*(m + 1)), x] - Dist[(b*c*p)/(d*(m + 1)), Int[((d*x)^(m + 1)*(a + b*ArcTanh[c*x])^(p - 1))/(1 -
 c^2*x^2), x], x] /; FreeQ[{a, b, c, d, m}, x] && IGtQ[p, 0] && (EqQ[p, 1] || IntegerQ[m]) && NeQ[m, -1]

Rule 5980

Int[(((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)*((f_.)*(x_))^(m_))/((d_) + (e_.)*(x_)^2), x_Symbol] :> Dist[f^2
/e, Int[(f*x)^(m - 2)*(a + b*ArcTanh[c*x])^p, x], x] - Dist[(d*f^2)/e, Int[((f*x)^(m - 2)*(a + b*ArcTanh[c*x])
^p)/(d + e*x^2), x], x] /; FreeQ[{a, b, c, d, e, f}, x] && GtQ[p, 0] && GtQ[m, 1]

Rule 266

Int[(x_)^(m_.)*((a_) + (b_.)*(x_)^(n_))^(p_), x_Symbol] :> Dist[1/n, Subst[Int[x^(Simplify[(m + 1)/n] - 1)*(a
+ b*x)^p, x], x, x^n], x] /; FreeQ[{a, b, m, n, p}, x] && IntegerQ[Simplify[(m + 1)/n]]

Rule 43

Int[((a_.) + (b_.)*(x_))^(m_.)*((c_.) + (d_.)*(x_))^(n_.), x_Symbol] :> Int[ExpandIntegrand[(a + b*x)^m*(c + d
*x)^n, x], x] /; FreeQ[{a, b, c, d, n}, x] && NeQ[b*c - a*d, 0] && IGtQ[m, 0] && ( !IntegerQ[n] || (EqQ[c, 0]
&& LeQ[7*m + 4*n + 4, 0]) || LtQ[9*m + 5*(n + 1), 0] || GtQ[m + n + 2, 0])

Rule 5910

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.), x_Symbol] :> Simp[x*(a + b*ArcTanh[c*x])^p, x] - Dist[b*c*p, In
t[(x*(a + b*ArcTanh[c*x])^(p - 1))/(1 - c^2*x^2), x], x] /; FreeQ[{a, b, c}, x] && IGtQ[p, 0]

Rule 260

Int[(x_)^(m_.)/((a_) + (b_.)*(x_)^(n_)), x_Symbol] :> Simp[Log[RemoveContent[a + b*x^n, x]]/(b*n), x] /; FreeQ
[{a, b, m, n}, x] && EqQ[m, n - 1]

Rule 5948

Int[((a_.) + ArcTanh[(c_.)*(x_)]*(b_.))^(p_.)/((d_) + (e_.)*(x_)^2), x_Symbol] :> Simp[(a + b*ArcTanh[c*x])^(p
 + 1)/(b*c*d*(p + 1)), x] /; FreeQ[{a, b, c, d, e, p}, x] && EqQ[c^2*d + e, 0] && NeQ[p, -1]

Rubi steps

\begin{align*} \int x^3 \left (a+b \tanh ^{-1}(c x)\right )^2 \, dx &=\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2-\frac{1}{2} (b c) \int \frac{x^4 \left (a+b \tanh ^{-1}(c x)\right )}{1-c^2 x^2} \, dx\\ &=\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2+\frac{b \int x^2 \left (a+b \tanh ^{-1}(c x)\right ) \, dx}{2 c}-\frac{b \int \frac{x^2 \left (a+b \tanh ^{-1}(c x)\right )}{1-c^2 x^2} \, dx}{2 c}\\ &=\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2-\frac{1}{6} b^2 \int \frac{x^3}{1-c^2 x^2} \, dx+\frac{b \int \left (a+b \tanh ^{-1}(c x)\right ) \, dx}{2 c^3}-\frac{b \int \frac{a+b \tanh ^{-1}(c x)}{1-c^2 x^2} \, dx}{2 c^3}\\ &=\frac{a b x}{2 c^3}+\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}-\frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{4 c^4}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2-\frac{1}{12} b^2 \operatorname{Subst}\left (\int \frac{x}{1-c^2 x} \, dx,x,x^2\right )+\frac{b^2 \int \tanh ^{-1}(c x) \, dx}{2 c^3}\\ &=\frac{a b x}{2 c^3}+\frac{b^2 x \tanh ^{-1}(c x)}{2 c^3}+\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}-\frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{4 c^4}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2-\frac{1}{12} b^2 \operatorname{Subst}\left (\int \left (-\frac{1}{c^2}-\frac{1}{c^2 \left (-1+c^2 x\right )}\right ) \, dx,x,x^2\right )-\frac{b^2 \int \frac{x}{1-c^2 x^2} \, dx}{2 c^2}\\ &=\frac{a b x}{2 c^3}+\frac{b^2 x^2}{12 c^2}+\frac{b^2 x \tanh ^{-1}(c x)}{2 c^3}+\frac{b x^3 \left (a+b \tanh ^{-1}(c x)\right )}{6 c}-\frac{\left (a+b \tanh ^{-1}(c x)\right )^2}{4 c^4}+\frac{1}{4} x^4 \left (a+b \tanh ^{-1}(c x)\right )^2+\frac{b^2 \log \left (1-c^2 x^2\right )}{3 c^4}\\ \end{align*}

Mathematica [A]  time = 0.0588042, size = 132, normalized size = 1.17 \[ \frac{3 a^2 c^4 x^4+2 a b c^3 x^3+2 b c x \tanh ^{-1}(c x) \left (3 a c^3 x^3+b \left (c^2 x^2+3\right )\right )+6 a b c x+b (3 a+4 b) \log (1-c x)-3 a b \log (c x+1)+b^2 c^2 x^2+3 b^2 \left (c^4 x^4-1\right ) \tanh ^{-1}(c x)^2+4 b^2 \log (c x+1)}{12 c^4} \]

Antiderivative was successfully verified.

[In]

Integrate[x^3*(a + b*ArcTanh[c*x])^2,x]

[Out]

(6*a*b*c*x + b^2*c^2*x^2 + 2*a*b*c^3*x^3 + 3*a^2*c^4*x^4 + 2*b*c*x*(3*a*c^3*x^3 + b*(3 + c^2*x^2))*ArcTanh[c*x
] + 3*b^2*(-1 + c^4*x^4)*ArcTanh[c*x]^2 + b*(3*a + 4*b)*Log[1 - c*x] - 3*a*b*Log[1 + c*x] + 4*b^2*Log[1 + c*x]
)/(12*c^4)

________________________________________________________________________________________

Maple [B]  time = 0.015, size = 278, normalized size = 2.5 \begin{align*}{\frac{{a}^{2}{x}^{4}}{4}}+{\frac{{b}^{2}{x}^{4} \left ({\it Artanh} \left ( cx \right ) \right ) ^{2}}{4}}+{\frac{{b}^{2}{\it Artanh} \left ( cx \right ){x}^{3}}{6\,c}}+{\frac{{b}^{2}x{\it Artanh} \left ( cx \right ) }{2\,{c}^{3}}}+{\frac{{b}^{2}{\it Artanh} \left ( cx \right ) \ln \left ( cx-1 \right ) }{4\,{c}^{4}}}-{\frac{{b}^{2}{\it Artanh} \left ( cx \right ) \ln \left ( cx+1 \right ) }{4\,{c}^{4}}}+{\frac{{b}^{2} \left ( \ln \left ( cx-1 \right ) \right ) ^{2}}{16\,{c}^{4}}}-{\frac{{b}^{2}\ln \left ( cx-1 \right ) }{8\,{c}^{4}}\ln \left ({\frac{1}{2}}+{\frac{cx}{2}} \right ) }-{\frac{{b}^{2}\ln \left ( cx+1 \right ) }{8\,{c}^{4}}\ln \left ( -{\frac{cx}{2}}+{\frac{1}{2}} \right ) }+{\frac{{b}^{2}}{8\,{c}^{4}}\ln \left ( -{\frac{cx}{2}}+{\frac{1}{2}} \right ) \ln \left ({\frac{1}{2}}+{\frac{cx}{2}} \right ) }+{\frac{{b}^{2} \left ( \ln \left ( cx+1 \right ) \right ) ^{2}}{16\,{c}^{4}}}+{\frac{{b}^{2}{x}^{2}}{12\,{c}^{2}}}+{\frac{{b}^{2}\ln \left ( cx-1 \right ) }{3\,{c}^{4}}}+{\frac{{b}^{2}\ln \left ( cx+1 \right ) }{3\,{c}^{4}}}+{\frac{{x}^{4}ab{\it Artanh} \left ( cx \right ) }{2}}+{\frac{ab{x}^{3}}{6\,c}}+{\frac{xab}{2\,{c}^{3}}}+{\frac{ab\ln \left ( cx-1 \right ) }{4\,{c}^{4}}}-{\frac{ab\ln \left ( cx+1 \right ) }{4\,{c}^{4}}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(x^3*(a+b*arctanh(c*x))^2,x)

[Out]

1/4*a^2*x^4+1/4*b^2*x^4*arctanh(c*x)^2+1/6/c*b^2*arctanh(c*x)*x^3+1/2*b^2*x*arctanh(c*x)/c^3+1/4/c^4*b^2*arcta
nh(c*x)*ln(c*x-1)-1/4/c^4*b^2*arctanh(c*x)*ln(c*x+1)+1/16/c^4*b^2*ln(c*x-1)^2-1/8/c^4*b^2*ln(c*x-1)*ln(1/2+1/2
*c*x)-1/8/c^4*b^2*ln(-1/2*c*x+1/2)*ln(c*x+1)+1/8/c^4*b^2*ln(-1/2*c*x+1/2)*ln(1/2+1/2*c*x)+1/16/c^4*b^2*ln(c*x+
1)^2+1/12*b^2*x^2/c^2+1/3/c^4*b^2*ln(c*x-1)+1/3/c^4*b^2*ln(c*x+1)+1/2*x^4*a*b*arctanh(c*x)+1/6*a*b*x^3/c+1/2*a
*b*x/c^3+1/4/c^4*a*b*ln(c*x-1)-1/4/c^4*a*b*ln(c*x+1)

________________________________________________________________________________________

Maxima [A]  time = 0.976638, size = 255, normalized size = 2.26 \begin{align*} \frac{1}{4} \, b^{2} x^{4} \operatorname{artanh}\left (c x\right )^{2} + \frac{1}{4} \, a^{2} x^{4} + \frac{1}{12} \,{\left (6 \, x^{4} \operatorname{artanh}\left (c x\right ) + c{\left (\frac{2 \,{\left (c^{2} x^{3} + 3 \, x\right )}}{c^{4}} - \frac{3 \, \log \left (c x + 1\right )}{c^{5}} + \frac{3 \, \log \left (c x - 1\right )}{c^{5}}\right )}\right )} a b + \frac{1}{48} \,{\left (4 \, c{\left (\frac{2 \,{\left (c^{2} x^{3} + 3 \, x\right )}}{c^{4}} - \frac{3 \, \log \left (c x + 1\right )}{c^{5}} + \frac{3 \, \log \left (c x - 1\right )}{c^{5}}\right )} \operatorname{artanh}\left (c x\right ) + \frac{4 \, c^{2} x^{2} - 2 \,{\left (3 \, \log \left (c x - 1\right ) - 8\right )} \log \left (c x + 1\right ) + 3 \, \log \left (c x + 1\right )^{2} + 3 \, \log \left (c x - 1\right )^{2} + 16 \, \log \left (c x - 1\right )}{c^{4}}\right )} b^{2} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^3*(a+b*arctanh(c*x))^2,x, algorithm="maxima")

[Out]

1/4*b^2*x^4*arctanh(c*x)^2 + 1/4*a^2*x^4 + 1/12*(6*x^4*arctanh(c*x) + c*(2*(c^2*x^3 + 3*x)/c^4 - 3*log(c*x + 1
)/c^5 + 3*log(c*x - 1)/c^5))*a*b + 1/48*(4*c*(2*(c^2*x^3 + 3*x)/c^4 - 3*log(c*x + 1)/c^5 + 3*log(c*x - 1)/c^5)
*arctanh(c*x) + (4*c^2*x^2 - 2*(3*log(c*x - 1) - 8)*log(c*x + 1) + 3*log(c*x + 1)^2 + 3*log(c*x - 1)^2 + 16*lo
g(c*x - 1))/c^4)*b^2

________________________________________________________________________________________

Fricas [A]  time = 2.09657, size = 354, normalized size = 3.13 \begin{align*} \frac{12 \, a^{2} c^{4} x^{4} + 8 \, a b c^{3} x^{3} + 4 \, b^{2} c^{2} x^{2} + 24 \, a b c x + 3 \,{\left (b^{2} c^{4} x^{4} - b^{2}\right )} \log \left (-\frac{c x + 1}{c x - 1}\right )^{2} - 4 \,{\left (3 \, a b - 4 \, b^{2}\right )} \log \left (c x + 1\right ) + 4 \,{\left (3 \, a b + 4 \, b^{2}\right )} \log \left (c x - 1\right ) + 4 \,{\left (3 \, a b c^{4} x^{4} + b^{2} c^{3} x^{3} + 3 \, b^{2} c x\right )} \log \left (-\frac{c x + 1}{c x - 1}\right )}{48 \, c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^3*(a+b*arctanh(c*x))^2,x, algorithm="fricas")

[Out]

1/48*(12*a^2*c^4*x^4 + 8*a*b*c^3*x^3 + 4*b^2*c^2*x^2 + 24*a*b*c*x + 3*(b^2*c^4*x^4 - b^2)*log(-(c*x + 1)/(c*x
- 1))^2 - 4*(3*a*b - 4*b^2)*log(c*x + 1) + 4*(3*a*b + 4*b^2)*log(c*x - 1) + 4*(3*a*b*c^4*x^4 + b^2*c^3*x^3 + 3
*b^2*c*x)*log(-(c*x + 1)/(c*x - 1)))/c^4

________________________________________________________________________________________

Sympy [A]  time = 2.24423, size = 168, normalized size = 1.49 \begin{align*} \begin{cases} \frac{a^{2} x^{4}}{4} + \frac{a b x^{4} \operatorname{atanh}{\left (c x \right )}}{2} + \frac{a b x^{3}}{6 c} + \frac{a b x}{2 c^{3}} - \frac{a b \operatorname{atanh}{\left (c x \right )}}{2 c^{4}} + \frac{b^{2} x^{4} \operatorname{atanh}^{2}{\left (c x \right )}}{4} + \frac{b^{2} x^{3} \operatorname{atanh}{\left (c x \right )}}{6 c} + \frac{b^{2} x^{2}}{12 c^{2}} + \frac{b^{2} x \operatorname{atanh}{\left (c x \right )}}{2 c^{3}} + \frac{2 b^{2} \log{\left (x - \frac{1}{c} \right )}}{3 c^{4}} - \frac{b^{2} \operatorname{atanh}^{2}{\left (c x \right )}}{4 c^{4}} + \frac{2 b^{2} \operatorname{atanh}{\left (c x \right )}}{3 c^{4}} & \text{for}\: c \neq 0 \\\frac{a^{2} x^{4}}{4} & \text{otherwise} \end{cases} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x**3*(a+b*atanh(c*x))**2,x)

[Out]

Piecewise((a**2*x**4/4 + a*b*x**4*atanh(c*x)/2 + a*b*x**3/(6*c) + a*b*x/(2*c**3) - a*b*atanh(c*x)/(2*c**4) + b
**2*x**4*atanh(c*x)**2/4 + b**2*x**3*atanh(c*x)/(6*c) + b**2*x**2/(12*c**2) + b**2*x*atanh(c*x)/(2*c**3) + 2*b
**2*log(x - 1/c)/(3*c**4) - b**2*atanh(c*x)**2/(4*c**4) + 2*b**2*atanh(c*x)/(3*c**4), Ne(c, 0)), (a**2*x**4/4,
 True))

________________________________________________________________________________________

Giac [A]  time = 1.25719, size = 215, normalized size = 1.9 \begin{align*} \frac{1}{4} \, a^{2} x^{4} + \frac{a b x^{3}}{6 \, c} + \frac{1}{16} \,{\left (b^{2} x^{4} - \frac{b^{2}}{c^{4}}\right )} \log \left (-\frac{c x + 1}{c x - 1}\right )^{2} + \frac{b^{2} x^{2}}{12 \, c^{2}} + \frac{1}{12} \,{\left (3 \, a b x^{4} + \frac{b^{2} x^{3}}{c} + \frac{3 \, b^{2} x}{c^{3}}\right )} \log \left (-\frac{c x + 1}{c x - 1}\right ) + \frac{a b x}{2 \, c^{3}} - \frac{{\left (3 \, a b - 4 \, b^{2}\right )} \log \left (c x + 1\right )}{12 \, c^{4}} + \frac{{\left (3 \, a b + 4 \, b^{2}\right )} \log \left (c x - 1\right )}{12 \, c^{4}} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(x^3*(a+b*arctanh(c*x))^2,x, algorithm="giac")

[Out]

1/4*a^2*x^4 + 1/6*a*b*x^3/c + 1/16*(b^2*x^4 - b^2/c^4)*log(-(c*x + 1)/(c*x - 1))^2 + 1/12*b^2*x^2/c^2 + 1/12*(
3*a*b*x^4 + b^2*x^3/c + 3*b^2*x/c^3)*log(-(c*x + 1)/(c*x - 1)) + 1/2*a*b*x/c^3 - 1/12*(3*a*b - 4*b^2)*log(c*x
+ 1)/c^4 + 1/12*(3*a*b + 4*b^2)*log(c*x - 1)/c^4